var should = require('should');
var config = require('../../config');
var dailyEnergyHandler = require('../../../app/servers/activity/handler/dailyEnergyReceiveHandler.js');
var configUtil = require('../../../app/util/configUtil');
var analyze = require('kc-analyze');

suite('测试checkHandler', function () {
    setup(function (done) {
        var analyze_config = configUtil.load('analyze');
        var game_config = configUtil.load('game');
        analyze.initialize({
            host: analyze_config.host,
            server_id: game_config.server_id
        });
        done();
    });

    //suite('sign', function () {
    //test('测试签到1', function (done) {
    //var msg = {};
    //msg.task_id = 1;
    //var session = {};
    //session.uid = config.role_id;
    //var daily_handler = new dailyEnergyHandler();
    //daily_handler.receive(msg, session, function (err, res) {
    //console.log('res:', res);
    //done();
    //});
    //});
    //});

    suite('sign', function () {
        test('测试签到1', function (done) {
            var msg = {};
            msg.task_id = 1;
            var session = {};
            session.uid = config.role_id;
            var daily_handler = new dailyEnergyHandler();
            daily_handler.retroactive(msg, session, function (err, res) {
                console.log('res:', res);
                done();
            });
        });
    });
});
